package com.mechat.util

import android.util.Log
import java.math.BigDecimal

class HeightUtils {
    fun centimetreToInches(height: String): String {
        val inches = Integer.parseInt(height.substring(0, height.indexOf("'")))
        val feet = Integer.parseInt(height.substring(height.indexOf("'") + 1, height.indexOf("\"")))
        Log.e("~~~", "centimetreToInches: $inches  --- $feet")
        return "${BigDecimal(inches * 30.48f + feet * 2.54).toInt()}"
    }
}